import {
  HomeOutlined,
  UploadOutlined,
  PictureOutlined,
  ProfileOutlined,
  OrderedListOutlined,
  FilterOutlined,
  TeamOutlined,
  UserOutlined,
  SettingOutlined,
  ShoppingCartOutlined,
} from "@ant-design/icons";

// 引入路由页面
import Home from "@/views/home/Index";

import Banner from "@/views/banner/Index";
import BannerList from "@/views/banner/List";
import BannerActive from "@/views/banner/Active";
import BannerAdd from "@/views/banner/Add";

import Product from "@/views/product/Index";
import ProductSearch from "@/views/product/Search";
import ProductList from "@/views/product/list/Index";
import ProductHomeList from "@/views/product/list/Home";
import ProductDetailList from "@/views/product/list/Detail";
import ProductCartList from "@/views/product/list/Cart";

import Shopping from "@/views/shopping/Index";
import ShoppingTabulation from "@/views/shopping/Tabulation";
import Cart from "@/views/shopping/Cart";

import Account from "@/views/account/Index";
import UserList from "@/views/account/UserList";
import AdminList from "@/views/account/AdminList";

import Setting from "@/views/setting/Index";

const menus = [
  {
    label: "系统首页",
    key: "/",
    icon: <HomeOutlined />,
    element: <Home />,
    keyid: "0-0",
  },
  {
    label: "轮播图管理",
    key: "/banner",
    icon: <UploadOutlined />,
    element: <Banner />,
    keyid: "0-1",
    children: [
      {
        index: 1,
        label: "首页轮播图",
        key: "/banner/home",
        keyid: "0-1-0",
        element: <BannerList />,
        icon: <PictureOutlined />,
      },
      {
        label: "活动页轮播图",
        key: "/banner/active",
        keyid: "0-1-1",
        element: <BannerActive />,
        icon: <PictureOutlined />,
      },

      {
        label: "添加轮播图",
        key: "/banner/add",
        keyid: "0-1-2",
        element: <BannerAdd />,
        icon: <PictureOutlined />,
      },
    ],
  },
  {
    label: "产品管理",
    key: "/pro",
    keyid: "0-2",
    icon: <ProfileOutlined />,
    element: <Product />,
    children: [
      {
        label: "产品列表",
        key: "/pro/list",
        keyid: "0-2-0",
        index: 1,
        element: <ProductList />,
        icon: <OrderedListOutlined />,
        children: [
          {
            index: 1,
            label: "首页产品列表",
            element: <ProductHomeList />,
            key: "/pro/list/home",
            keyid: "0-2-0-0",
          },
          {
            label: "详情推荐列表",
            element: <ProductDetailList />,
            key: "/pro/list/detail",
            keyid: "0-2-0-1",
          },
          {
            label: "购物车推荐列表",
            element: <ProductCartList />,
            key: "/pro/list/cart",
            keyid: "0-2-0-2",
          },
        ],
      },
      {
        label: "筛选列表",
        key: "/pro/search",
        keyid: "0-2-1",
        element: <ProductSearch />,
        icon: <FilterOutlined />,
      },
    ],
  },
  {
    label: "购物",
    key: "/shopping",
    keyid: "0-3",
    icon: <ShoppingCartOutlined />,
    element: <Shopping />,
    children: [
      {
        index: 1,
        label: "商品列表",
        key: "/shopping/tabulation",
        keyid: "0-3-1",
        element: <ShoppingTabulation />,
        icon: <ShoppingCartOutlined />,
      },
      {
        label: "购物车",
        key: "/shopping/cart",
        keyid: "0-3-2",
        element: <Cart />,
        icon: <ShoppingCartOutlined />,
      },
    ],
  },
  {
    label: "账户管理",
    key: "/account",
    keyid: "0-4",
    icon: <TeamOutlined />,
    element: <Account />,
    children: [
      {
        index: 1,
        label: "用户列表",
        key: "/account/userlist",
        keyid: "0-4-1",
        element: <UserList />,
        icon: <UserOutlined />,
      },
      {
        label: "管理员列表",
        key: "/account/adminlist",
        keyid: "0-4-2",
        element: <AdminList />,
        icon: <UserOutlined />,
      },
    ],
  },
  {
    label: "设置",
    key: "/setting",
    keyid: "0-5",
    icon: <SettingOutlined />,
    element: <Setting />,
  },
];

export default menus;
